home *** CD-ROM | disk | FTP | other *** search
- Path: nntp.teleport.com!sschaem
- From: sschaem@teleport.com (Stephan Schaem)
- Newsgroups: comp.sys.amiga.programmer
- Subject: Re: New C2P
- Date: 9 Jan 1996 18:33:52 GMT
- Organization: Teleport - Portland's Public Access (503) 220-1016
- Distribution: world
- Message-ID: <4cuceg$9an@maureen.teleport.com>
- References: <4ctiib$2ok@irz305.inf.tu-dresden.de>
- NNTP-Posting-Host: kelly.teleport.com
- X-Newsreader: TIN [version 1.2 PL2]
-
- Sven Steiniger (ss37@irz.inf.tu-dresden.de) wrote:
-
- : - Stephan Schaem (sschaem@teleport.com) <4cjl2o$4im@maureen.teleport.com>
- : >: - are there any very fast c2p which use a comparebuffer ?
- : >
- : > depand on the aplication I guess... The amiga mac emulator ShapwShifter
- : > has a range of driver that use Delta/checksum/mmu buffer in conjunction
- : > with the plannar/chunky buffer.
-
- : Could you give me a hint what a Delta/checksum/mmu buffer is ?
- : ( I use a comparebuffer which check if a block of 8 pixels have changed. If
- : yes then the comparebuffer is updated and the converter starts. If not I
- : simply step to the next block)
-
- delta: I think that what they call compare.
-
- checksum: I call it that way ;)
-
- .loop ml (a0)+,d1
- REPEAT 15
- add.l (a0)+,d1
- ENDR
- cmp.l (a1),d1
- beq.b .otherstateloop
- ml d1,(a1)+
- .c2p ;c2p 64 8bit pixels
- dbra d0,.loop
-
- mmu:
-
- You partition your chunky buffer in X k pages.
- You check the modified bit in the mmu page table descriptor, and
- go do a checksum based c2p on it if the page is 'dirty'.
- This is great for something with localized screen modification,
- and 'static' display.
- In shapeshifter for example, no CPU will be used for the c2p code
- while you compile... but if you play a quicktime movie it will only
- checksum from ~windowy1pos to ~windowy2pos and c2p only the changing
- data.
-
- : Also someone wrote that you could do 12 or 13 instructions during chip
- : write. Is there somewhere (in aminet) a time-table on this ?
- : I found a c2p-converter which use selfmodifying code. This one copy himself
- : to a quadword-align memory-position. Does this give any advantages ? (I
- : think a 8bpl c2p is small enough to fit into the cache)
-
- It depand alot ... you cant write your own inst 'timer' in a flash.
- (It work for me, but might for you).
-
- mw #$4000,($dff09a).l
- mw #$0100,($dff096).l
- mw #$8400,($dff096).l
- .Loop cmp.b #100,($dff006).l
- bne.b .Loop
- mw #$004,($dff180).l
- mw #iteration to fit frame,d7
- .. REPEAT X
- You code to test
- ENDR
- dbra d7,..
- mw #$fff,($dff180).l
- btst #6,($bfe001).l
- bne .Loop
- mw #$8100,($dff096).l
- mw #$0400,($dff096).l
-
- Then I do X*iteration*60 = 'mips'
- If your code is a "add.l d1,d0" You will get 12.5 mips
- on a 25mhz 030. (100 for X, 2080 for iteration)
- Now create a large chip section, and replace "add.l..."
- by "move.l d0,(a1)+" ?
- Dont forget not to set X to high, like X * codesize should not
- be > cachesize. (But the closer to it is better because you are timming
- the dbra too :)
- Now just add instruction below the "move.l " , add.l one since you know
- its timing now ... and see how many you can fit.
-
- You know you have your optimal iteration count when you only see a short
- dnacing white hline at the top level of the background/blue transition.
-
- Stephan
-
-